% File:     usecase.tex
% Author:   Ryan J. Bovorasmy
% Date:     2007-06-24
% Desc:     This template is used to add a use case to the srs.tex template.
% Rev:      [2007-06-24, Ryan J. Bovorasmy] First major revision.
% Rev:      [2007-10-23, Ryan J. Bovorasmy] Created from template.
%

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%
%% INSTRUCTIONS:
%%
%% This document can be used to create a use case for use with the srs.tex
%% template.
%%
%% Certain sections (such as this one) are delimited with special comments.
%% These sections contain similar material, and should be treated as a group.
%%
%% Comments beginning with *** indicate that editing is necessary in that
%% area. Example:
%%
%% *** Section description. This section needs editing.
%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

%||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
%
% BEGIN COMMAND SECTION
% Do Not edit this section unless you know what you are doing.
%
\providecommand{\usecase}{~}
\providecommand{\usehistory}{~}
\providecommand{\uc}{UC\theusecase}
\providecommand{\actor}{~}
\providecommand{\system}{~}
\setcounter{flownumber}{0}
\providecommand{\flowcounter}{\addtocounter{flownumber}{1} \theflownumber}
%
% END COMMAND SECTION
%
%||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||

%==============================================================================
%
% BEGIN VARIABLE SECTION
%
% *** Enter the name of the use case here:
%
\renewcommand{\usecase}{User Saves Organism Data}
%
% *** Enter the revision history here.
% The format of the history command is as follows:
%
% \history{NAME}{DATE}{BRIEF DESCRIPTION\\}
%
% Notice that a newline is REQUIRED after the description.
%
\renewcommand{\usehistory}%
{%
  \history{Ryan J. Bovorasmy}{2007-10-23}{First major revision.\\}
}
%
% END VARIABLE SECTION
%
%==============================================================================
\addtocounter{usecase}{1}
\subsection{\uc{}: \usecase{}}

%------------------------------------------------------------------------------
% Do not edit this.
%
\paragraph{\uc{}: Revision History}~\\{}
\begin{table}[htbp]
  \begin{tabular}{|l|l|p{.4\textwidth}|}
    \usehistory
    \hline
  \end{tabular}
\end{table}

%------------------------------------------------------------------------------
% *** Enter a brief description.
%
\paragraph{\uc{}: Brief Description}
The user saves the all information about an organism (organism data).

% %------------------------------------------------------------------------------
% % *** Image/model
% %
% % Uncomment this section if you would like to add an image of the use case
% % here.
% %
% \paragraph{\uc{}: Model}
% If graphics are being used, add an image of the use case here.

%------------------------------------------------------------------------------
% ** Create a list of actors.
%
\paragraph{\uc{}: Actors}
\begin{description}
  \item[User] The user of the \projectname{} project.
  \item[\projectname{}] The \projectname{} software.
\end{description}

%------------------------------------------------------------------------------
% *** Pre-conditions.
%
\paragraph{\uc{}: Pre-Conditions}
\begin{description}
  \item[Organism Exists] At least one organism has been created.
\end{description}

%------------------------------------------------------------------------------
% *** Basic flow.
%
% First enter in the actor name and system name.
%
\renewcommand{\actor}{User}
\renewcommand{\system}{\projectname{}}
\paragraph{\uc{}: Basic Flow}~\\{}~\\{}
\begin{tabular}{|c|p{.4\textwidth}|p{.4\textwidth}|}
  \hline
  \# & \actor{} & \system{} \\
  \hline
  %
  % *** Next, create the rows of the table.
  % Because only one person can be acting at a time, each row should contain
  % one space. Replace the other space with the action.
  %
  \flowcounter{} & The user indicates that they wish to save organism data. & ~ \\
  \hline
  \flowcounter{} & ~ & The system displays a list of organisms that are possible to save. \\
  \hline
  \flowcounter{} & The user selected the organism they wish to save. & ~ \\
  \hline  
  \flowcounter{} & ~ & The system prompts the user for a file location. \\
  \hline
  \flowcounter{} & The user inputs a file location. & ~ \\
  \hline
  \flowcounter{} & ~ & The system prepares the organism data. \\
  \hline
  \flowcounter{} & ~ & The system saves the organism data at the selected file location. \\
  \hline
\end{tabular}


%------------------------------------------------------------------------------
% *** Alternative flow.
%
\paragraph{\uc{}: Alternative Flows}
\begin{description}
  \item[User Cancels Save] The user may cancel the save process at any time. When this occurs, the system shall revert to the state it was in before the save was initiated.
\end{description}

%------------------------------------------------------------------------------
% *** Exception flow.
%
\paragraph{\uc{}: Exception Flows}
\begin{description}
  \item[Organism Does Not Exist] In the case that the selected organism does not exist, the system shall revert to the state it was in before the remove was initiated.
  \item[Data Error] In the case that it is not possible for the system to correctly prepare the organism data for saving, the system shall revert to the state it was in before the save was initiated.
  \item[File Unwritable] In the case that the selected file is unwritable or invalid, the system shall revert to the state it was in before the save was initiated.
\end{description}

%------------------------------------------------------------------------------
% *** Post-conditions.
%
\paragraph{\uc{}: Post-Conditions}
\begin{description}
  \item[Organism Data Saved] The organism data for the selected organism is stored in the selected file location.
\end{description}

%------------------------------------------------------------------------------
% *** Enter any additional notes here.
%
%\paragraph{\uc{}: Additional Notes}
%As used in this use case, organism data refers to the set of traits and meta-data that make up a base organism.
